import React, { useEffect } from "react";
import { View } from "@tarojs/components";
import Request from '@/utils/request';
import Swiper from "@/components/index/Swiper";
import ToolsContent from "@/components/index/ToolsContent";
import Activity from "@/components/common/Activity";
import Like from "@/components/index/Like";

export default function index() {
  useEffect(() => {
    (async () => {
      let res = await Request.get('/api/products');
      console.log(res, 'products')
    }
    )();
  }, []);

  return (
    <View className="wrapper theme-bg-white">
      <Swiper />
      <ToolsContent className="mx-auto"/>
      <Activity />
      <Like />
    </View>
  );
}

